home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 7 / BBS in a Box - Macintosh - Volume VII (BBS in a Box) (January 1993).iso / Files / Hyper / Hy-Hyperi / HyperBBS 2.0.cpt / HyperBBS 2.0 / Hyper House / stack_-1.xml < prev    next >
Extensible Markup Language  |  1992-07-14  |  10KB  |  35 lines

  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <!DOCTYPE stack PUBLIC "-//Apple, Inc.//DTD stack V 2.0//EN" "" >
  3. <stack>
  4.     <name>in</name>
  5.     <id>-1</id>
  6.     <cardCount>13</cardCount>
  7.     <cardID>6578</cardID>
  8.     <listID>7651</listID>
  9.     <cantModify><false /></cantModify>
  10.     <cantDelete><false /></cantDelete>
  11.     <cantAbort><false /></cantAbort>
  12.     <cardSize>
  13.         <width>512</width>
  14.         <height>342</height>
  15.     </cardSize>
  16.     <script>on openStackpush recent cardend openStack--   -- this is the section that should apear in each section's stack!-- Open/init card code:-- Override to do local initialization (remember to pass if approp.).on openCardglobal doingBackFields, nextFieldNum, onLine, crcFlgglobal lookingForput empty into lookingForset cursor to 4set lockScreen to truesend initFields to this cardset lockScreen to falseif onLine thensendString return & return-- get short name of this card-- if (word 1 of it <> "card") or (word 2 of it <> "id") then-- if it is not empty then sendString it & return-- end ifrepeat with i = 1 to the number of fieldsget the lockText of field iif isEditable(name of field i) and (not it) thennext repeatend ifif not the visible of field i then next repeatif notThere(name of field i) then next repeatput short name of field i into nif (word 1 of n is not "Bkgnd") or ¬¨(word 2 of n is not "field") or (word 3 of n is not "id") thenget isLong("field " & i)if it then get n & ":" & returnelse get n & ": "else get emptyif sendWithAbort(it & field i) thensend abortOCexit openCardend ifend repeatrepeat with i = 1 to the number of card fieldsget the lockText of card field iif isEditable(name of card field i) and (not it) then next repeatif notThere(name of card field i) then next repeatif not the visible of card field i then next repeatput short name of card field i into nif (word 1 of n is not "card") or ¬¨(word 2 of n is not "field") or (word 3 of n is not "id") thenget isLong("card field " & i)if it then get n & ":" & returnelse get n & ": "else get emptyif sendWithAbort(it & card field i) thensend abortOCexit openCardend ifend repeatif crcFlg then disCRCflushInputend ifput true into doingBackFieldsput 1 into nextFieldNumset cursor to 0end openCard-- incase of aborton abortOCflushInputput true into doingBackFieldsput 1 into nextFieldNumset cursor to 0end abortOCon initFieldsglobal initFsif initFs thenrepeat with i = 1 to the number of fieldsif isEditable(name of field i) then put empty into field iend repeatrepeat with i = 1 to the number of card fieldsif isEditable(name of card field i) then put empty into card field iend repeatend ifend initFieldson displayFieldsend displayFieldson disCRCput 0 into theCRCrepeat with i = 1 to the number of fieldsget the lockText of field iif isEditable(name of field i) and (not it) then next repeatif not the visible of field i then next repeatput stringCRC(theCRC,field i) into theCRCend repeatrepeat with i = 1 to the number of card fieldsget the lockText of card field iif isEditable(name of card field i) and (not it) then next repeatif not the visible of card field i then next repeatput stringCRC(theCRC,card field i) into theCRCend repeatsendString return & ".C=" & theCRC & returnend disCRC-- Send text code:on sendString stringglobal onLineif onLine thenresetTimersendSPort stringend ifend sendStringon sendVanilla stringglobal onLineif onLine thenresetTimerconfigureSPort linefeedOffsendSPort stringconfigureSPort linefeedOnend ifend sendVanilla-- Field type testing code:function isEditable fget the script of fif "-" & "- editable" is in it then return trueelse return falseend isEditablefunction isLong fget the script of fif "-" & "- long" is in it then return trueelse return falseend isLongfunction isInvisible fget the script of fif "-" & "- invisible" is in it then return trueelse return falseend isInvisiblefunction notThere fget the script of fif "-" & "- notThere" is in it then return trueelse return falseend notThereon stopNowglobal sysTOValput charsAvailable() into charCntif charCnt is not zero thenput recvChars(charCnt) into incomingif (numToChar(19) is in incoming) thenflushInputput the secs into wasrepeat while charsAvailable() is zeroif the secs > (was + sysTOVal) then exit repeatend repeatflushinputend ifend ifend stopNowfunction sendWithAbort theTextglobal sendAborted, sysTOValget theTextrepeat with i = 1 to the number of lines in itsendString line i of it & returnput charsAvailable() into charCntif charCnt is not zero thenput recvChars(charCnt) into incomingif (numToChar(3) is in incoming) or ¬¨(numToChar(15) is in incoming) or ¬¨(numToChar(24) is in incoming) thenput true into sendAbortedreturn trueexit sendWithAbortelseif (numToChar(19) is in incoming) thenflushInputput the secs into wasrepeat while charsAvailable() is zeroif the secs > (was + sysTOVal) then exit repeatend repeatflushinputend ifend ifend ifend repeatreturn falseend sendWithAborton promptFieldput short name of the target into nget word 1 of nif (it is "card") or (it is "Bkgnd") thenget (word 2 of n is not "field") or (word 3 of n is not "id")else get trueif it thenif isLong(the target) then put ":" & return after nelse put ": " after nsendString nend ifend promptFieldon lookingForNothingglobal doingBackFields, nextFieldNumif doingBackFields thenrepeatif nextFieldNum > the number of fields then exit repeatput nextFieldNum into iadd 1 to nextFieldNumget the lockText of field iif (not isEditable(name of field i)) or it then next repeatif not the visible of field i then next repeatput empty into field isend promptField to field iif isLong(name of field i) thensendString "[End with a period (.) on a line by itself]" & returnfillField name of field i,false,isInvisible(name of field i)else fillField name of field i,true,isInvisible(name of field i)exit lookingForNothingend repeatput false into doingBackFieldsput 1 into nextFieldNumend ifrepeatif nextFieldNum > the number of card fields then exit repeatput nextFieldNum into iadd 1 to nextFieldNumget the lockText of card field iif (not isEditable(name of card field i)) or it then next repeatif not the visible of card field i then next repeatput empty into card field isend promptField to card field iif isLong(name of card field i) thensendString "[End with a period (.) on a line by itself]" & returnfillField name of card field i,false,¬¨isInvisible(name of card field i)else fillField name of card field i,true,¬¨isInvisible(name of card field i)exit lookingForNothingend repeatsend cardFilled to this cardend lookingForNothing-- Button related code:on displayButtonsglobal onLine, errorCountif onLine thenflushInputput empty into textget ">> "repeat with i = 1 to the number of background buttonsif not the visible of background button i then next repeatif notThere(name of bg button i) then next repeatput it & short name of background button i after textget ", "end repeatrepeat with i = 1 to the number of cd buttonsif not the visible of cd button i then next repeatif notThere(name of cd button i) then next repeatput it & short name of cd button i after textget ", "end repeatif it is ", " thensendString text & ": "put 0 into errorCountlookFor "singleChar","pushButton"else send noButtons to this cardend ifend displayButtonson cardFilledsend displayButtons to this cardend cardFilled--  --                   -- end of stuff to put in every stackon logoffUserglobal userID, initialSecs, recordLoads, loadLog, userAreasglobal newUserAreasif userID is not empty thenput the lockScreen into oldLockset lockScreen to trueput the lockMessages into oldLMset lockMessages to truepush cardgo to stack "UserList"go to userIDget trunc((the secs - initialSecs)/60)+1put it into field "minutes on"if recordLoads thenget loadLog & field "comments"if the number of lines of it > 100 thendelete line 101 to (the number of lines of it) of itend ifput it into field "comments"end ifget newUserAreas & field "userAreas"if the number of lines of it > 100 thendelete line 101 to (the number of lines of it) of itend ifput it into field "userAreas"pop cardset lockMessages to oldLMset lockScreen to oldLockput empty into userIDend ifend logoffUseron changeAutoWrapglobal onLineif onLine thenif "autoWrapOn" is in SPortConfiguration() thenconfigureSPort autoWrapOffelseconfigureSPort autoWrapOnend ifend ifend changeAutoWrap</script>
  17.     <background id="2607" file="background_2607.xml" name="" />
  18.     <background id="2974" file="background_2974.xml" name="Descriptive Card" />
  19.     <background id="3188" file="background_3188.xml" name="Show One Time" />
  20.     <background id="6224" file="background_6224.xml" name="Menu Choices in Fields" />
  21.     <card id="6578" file="card_6578.xml" marked="false" name="" owner="2607" />
  22.     <card id="6816" file="card_6816.xml" marked="false" name="" owner="2607" />
  23.     <card id="8891" file="card_8891.xml" marked="false" name="" owner="2607" />
  24.     <card id="8427" file="card_8427.xml" marked="false" name="" owner="2607" />
  25.     <card id="4291" file="card_4291.xml" marked="false" name="" owner="2607" />
  26.     <card id="2110" file="card_2110.xml" marked="false" name="Logon Message" owner="2607" />
  27.     <card id="4848" file="card_4848.xml" marked="false" name="Number chng Qmsg" owner="3188" />
  28.     <card id="5995" file="card_5995.xml" marked="false" name="Main Menu" owner="6224" />
  29.     <card id="2352" file="card_2352.xml" marked="false" name="Utilities" owner="6224" />
  30.     <card id="7914" file="card_7914.xml" marked="false" name="File Section" owner="6224" />
  31.     <card id="8039" file="card_8039.xml" marked="false" name="Public Boards" owner="6224" />
  32.     <card id="8582" file="card_8582.xml" marked="false" name="Classifieds" owner="6224" />
  33.     <card id="5829" file="card_5829.xml" marked="false" name="BBS Description" owner="2974" />
  34. </stack>
  35.